package com.lvy.hczn.front.system.domain.business;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.lvy.hczn.front.common.core.domain.BaseModel;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.math.BigDecimal;
import java.util.Date;

@Data
@TableName("sku")
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "sku")
public class Sku extends BaseModel<Sku> {

    @ApiModelProperty(value = "主键,自增长,平台商品SKU")
    private String barcodeId;

    @ApiModelProperty(value = "来源")
    private String sourceId;

    @ApiModelProperty(value = "商品id")
    private String spuId;

    @ApiModelProperty(value = "商家编码，关联seller_info表seller_code字段")
    private String sellerCode;

    @ApiModelProperty(value = "站点编码")
    private String siteCode;

    @ApiModelProperty(value = "供应商编码")
    private String supplierCode;

    @ApiModelProperty(value = "平台商品编码，关联product_seller_goods表product_sys_code字段")
    private String productSysCode;

    @ApiModelProperty(value = "商家商品SKU")
    private String barcodeCode;

    @ApiModelProperty(value = "平台商品SKU编码")
    private String barcodeSysCode;

    @ApiModelProperty(value = "国际商品SKU(国际码)")
    private String intlCode;

    @ApiModelProperty(value = "箱码")
    private String innerCode;

    @ApiModelProperty(value = "商品SKU零售价")
    private BigDecimal barcodePrice;

    @ApiModelProperty(value = "销售价")
    private BigDecimal specPrice;

    @ApiModelProperty(value = "sku成本价")
    private BigDecimal costPrice;

    @ApiModelProperty(value = "最新进货价")
    private BigDecimal buyingPrice;

    @ApiModelProperty(value = "进项税%（字典选择）")
    private BigDecimal inputTax;

    @ApiModelProperty(value = "销项税%(字典选择)")
    private BigDecimal outputTax;

    @ApiModelProperty(value = "状态: -1为删除，1为审核通过，2为待处理, 3待审核, 4驳回，5撤回")
    private Integer status;

    @ApiModelProperty(value = "默认排序")
    private Integer sort;

    @ApiModelProperty(value = "重量")
    private BigDecimal heft;

    @ApiModelProperty(value = "销售属性")
    private String salesAttr;

    @ApiModelProperty(value = "sku主图")
    private String skuUrl;

    @ApiModelProperty(value = "商品规格")
    private String specification;

    @ApiModelProperty(value = "商品体积(cm³)")
    private BigDecimal volume;

    @ApiModelProperty(value = "浮动范围")
    private BigDecimal floatRange;


    @TableField(exist = false)
    private String salesAttrStr;

    /**
     * 多规格中第一个sku编号
     */
    @TableField(exist = false)
    private String barcodeSysCodeFirstOne;
}
